<?php
namespace Application\Entity;

class UpdateReader {

    public $userID;
    public $birthday;
    public $sex;
    public $email;
    public $phoneNumber;
    public $residentAddress;
    public $nativePlace;
    public $description;
    public $profilePhoto;

    public function exchangeArray($data) {
        $this->userID = (isset($data['userID'])) ? $data['userID'] : null;
        $this->birthday = (isset($data['birthday'])) ? $data['birthday'] : null;
        $this->sex = (isset($data['sex'])) ? $data['sex'] : null;
        $this->email = (isset($data['email'])) ? $data['email'] : null;
        $this->phoneNumber = (isset($data['phoneNumber'])) ? $data['phoneNumber'] : null;
        $this->residentAddress = (isset($data['residentAddress'])) ? $data['residentAddress'] : null;
        $this->nativePlace = (isset($data['nativePlace'])) ? $data['nativePlace'] : null;
        $this->description = (isset($data['description'])) ? $data['description'] : null;
        $this->profilePhoto = (isset($data['profilePhoto'])) ? $data['profilePhoto'] : null;
    }

    public function getArrayCopy() {
        return get_object_vars($this);
    }

}

?>
